package fmod.fmod;

import fmod.javafmod;
import fmod.javafmodJNI;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Locale;
import zombie.ZomboidFileSystem;
import zombie.characters.IsoPlayer;
import zombie.core.Core;
import zombie.core.Rand;
import zombie.core.logger.ExceptionLogger;
import zombie.debug.DebugLog;
import zombie.iso.Vector2;

/* loaded from: FMODManager.class */
public class FMODManager {
    public static FMODManager instance = new FMODManager();
    public static int FMOD_STUDIO_INIT_NORMAL = 0;
    public static int FMOD_STUDIO_INIT_LIVEUPDATE = 1;
    public static int FMOD_STUDIO_INIT_ALLOW_MISSING_PLUGINS = 2;
    public static int FMOD_STUDIO_INIT_SYNCHRONOUS_UPDATE = 4;
    public static int FMOD_STUDIO_INIT_DEFERRED_CALLBACKS = 8;
    public static int FMOD_INIT_NORMAL = 0;
    public static int FMOD_INIT_STREAM_FROM_UPDATE = 1;
    public static int FMOD_INIT_MIX_FROM_UPDATE = 2;
    public static int FMOD_INIT_3D_RIGHTHANDED = 4;
    public static int FMOD_INIT_CHANNEL_LOWPASS = 256;
    public static int FMOD_INIT_CHANNEL_DISTANCEFILTER = 512;
    public static int FMOD_INIT_PROFILE_ENABLE = 65536;
    public static int FMOD_INIT_VOL0_BECOMES_VIRTUAL = 131072;
    public static int FMOD_INIT_GEOMETRY_USECLOSEST = 262144;
    public static int FMOD_INIT_PREFER_DOLBY_DOWNMIX = 524288;
    public static int FMOD_INIT_THREAD_UNSAFE = 1048576;
    public static int FMOD_INIT_PROFILE_METER_ALL = 2097152;
    public static int FMOD_DEFAULT = 0;
    public static int FMOD_LOOP_OFF = 1;
    public static int FMOD_LOOP_NORMAL = 2;
    public static int FMOD_LOOP_BIDI = 4;
    public static int FMOD_2D = 8;
    public static int FMOD_3D = 16;
    public static int FMOD_HARDWARE = 32;
    public static int FMOD_SOFTWARE = 64;
    public static int FMOD_CREATESTREAM = 128;
    public static int FMOD_CREATESAMPLE = 256;
    public static int FMOD_CREATECOMPRESSEDSAMPLE = 512;
    public static int FMOD_OPENUSER = 1024;
    public static int FMOD_OPENMEMORY = 2048;
    public static int FMOD_OPENMEMORY_POINT = 268435456;
    public static int FMOD_OPENRAW = 4096;
    public static int FMOD_OPENONLY = 8192;
    public static int FMOD_ACCURATETIME = 16384;
    public static int FMOD_MPEGSEARCH = 32768;
    public static int FMOD_NONBLOCKING = 65536;
    public static int FMOD_UNIQUE = 131072;
    public static int FMOD_3D_HEADRELATIVE = 262144;
    public static int FMOD_3D_WORLDRELATIVE = 524288;
    public static int FMOD_3D_INVERSEROLLOFF = 1048576;
    public static int FMOD_3D_LINEARROLLOFF = 2097152;
    public static int FMOD_3D_LINEARSQUAREROLLOFF = 4194304;
    public static int FMOD_3D_INVERSETAPEREDROLLOFF = 8388608;
    public static int FMOD_3D_CUSTOMROLLOFF = 67108864;
    public static int FMOD_3D_IGNOREGEOMETRY = 1073741824;
    public static int FMOD_IGNORETAGS = 33554432;
    public static int FMOD_LOWMEM = 134217728;
    public static int FMOD_LOADSECONDARYRAM = 536870912;
    public static int FMOD_VIRTUAL_PLAYFROMSTART = Integer.MIN_VALUE;
    public static int FMOD_PRESET_OFF = 0;
    public static int FMOD_PRESET_GENERIC = 1;
    public static int FMOD_PRESET_PADDEDCELL = 2;
    public static int FMOD_PRESET_ROOM = 3;
    public static int FMOD_PRESET_BATHROOM = 4;
    public static int FMOD_PRESET_LIVINGROOM = 5;
    public static int FMOD_PRESET_STONEROOM = 6;
    public static int FMOD_PRESET_AUDITORIUM = 7;
    public static int FMOD_PRESET_CONCERTHALL = 8;
    public static int FMOD_PRESET_CAVE = 9;
    public static int FMOD_PRESET_ARENA = 10;
    public static int FMOD_PRESET_HANGAR = 11;
    public static int FMOD_PRESET_CARPETTEDHALLWAY = 12;
    public static int FMOD_PRESET_HALLWAY = 13;
    public static int FMOD_PRESET_STONECORRIDOR = 14;
    public static int FMOD_PRESET_ALLEY = 15;
    public static int FMOD_PRESET_FOREST = 16;
    public static int FMOD_PRESET_CITY = 17;
    public static int FMOD_PRESET_MOUNTAINS = 18;
    public static int FMOD_PRESET_QUARRY = 19;
    public static int FMOD_PRESET_PLAIN = 20;
    public static int FMOD_PRESET_PARKINGLOT = 21;
    public static int FMOD_PRESET_SEWERPIPE = 22;
    public static int FMOD_PRESET_UNDERWATER = 23;
    public static int FMOD_TIMEUNIT_MS = 1;
    public static int FMOD_TIMEUNIT_PCM = 2;
    public static int FMOD_TIMEUNIT_PCMBYTES = 4;
    public static int FMOD_STUDIO_PLAYBACK_PLAYING = 0;
    public static int FMOD_STUDIO_PLAYBACK_SUSTAINING = 1;
    public static int FMOD_STUDIO_PLAYBACK_STOPPED = 2;
    public static int FMOD_STUDIO_PLAYBACK_STARTING = 3;
    public static int FMOD_STUDIO_PLAYBACK_STOPPING = 4;
    public static int FMOD_SOUND_FORMAT_NONE = 0;
    public static int FMOD_SOUND_FORMAT_PCM8 = 1;
    public static int FMOD_SOUND_FORMAT_PCM16 = 2;
    public static int FMOD_SOUND_FORMAT_PCM24 = 3;
    public static int FMOD_SOUND_FORMAT_PCM32 = 4;
    public static int FMOD_SOUND_FORMAT_PCMFLOAT = 5;
    public static int FMOD_SOUND_FORMAT_BITSTREAM = 6;
    ArrayList<Long> Sounds = new ArrayList<>();
    ArrayList<Long> Instances = new ArrayList<>();
    public long channelGroupInGameNonBankSounds = 0;
    private final HashMap<String, FMOD_STUDIO_PARAMETER_DESCRIPTION> parameterDescriptionMap = new HashMap<>();
    private final HashMap<String, FMOD_STUDIO_EVENT_DESCRIPTION> eventDescriptionMap = new HashMap<>();
    int c = 0;
    Vector2 move = new Vector2(0.0f, 0.0f);
    Vector2 pos = new Vector2(-400.0f, -400.0f);
    float x = 0.0f;
    float y = 0.0f;
    float z = 0.0f;
    float vx = 0.02f;
    float vy = 0.01f;
    float vz = 0.0f;
    private int numListeners = 1;
    private final HashMap<String, Long> fileToSoundMap = new HashMap<>();
    private final int[] reverbPreset = {-1, -1, -1, -1};

    public void init() {
        javafmodJNI.init();
        if (javafmod.FMOD_System_Create() != 0) {
            Core.SoundDisabled = true;
            return;
        }
        if (javafmod.FMOD_System_Init(1024, FMOD_STUDIO_INIT_NORMAL | (Core.bDebug ? FMOD_STUDIO_INIT_LIVEUPDATE : 0), FMOD_INIT_NORMAL | FMOD_INIT_CHANNEL_DISTANCEFILTER | FMOD_INIT_CHANNEL_LOWPASS | FMOD_INIT_VOL0_BECOMES_VIRTUAL | (Core.bDebug ? FMOD_INIT_PROFILE_ENABLE | FMOD_INIT_PROFILE_METER_ALL : 0)) != 0) {
            Core.SoundDisabled = true;
            return;
        }
        javafmod.FMOD_System_Set3DSettings(1.0f, 1.0f, 1.0f);
        loadBank("ZomboidSound.strings");
        loadBank("ZomboidMusic");
        loadBank("ZomboidSound");
        loadBank("ZomboidSoundMP");
        this.channelGroupInGameNonBankSounds = javafmod.FMOD_System_CreateChannelGroup("InGameNonBank");
        initGlobalParameters();
        initEvents();
    }

    private String bankPath(String str) throws IOException {
        return new File("./media/sound/banks/Desktop/" + str + ".bank").getCanonicalFile().getPath();
    }

    private long loadBank(String str) {
        try {
            long FMOD_Studio_System_LoadBankFile = javafmod.FMOD_Studio_System_LoadBankFile(bankPath(str));
            if (FMOD_Studio_System_LoadBankFile > 0) {
                javafmod.FMOD_Studio_LoadSampleData(FMOD_Studio_System_LoadBankFile);
            }
            return FMOD_Studio_System_LoadBankFile;
        } catch (Exception e) {
            ExceptionLogger.logException(e);
            return 0L;
        }
    }

    /* loaded from: FMODManager$TestZombieInfo.class */
    public static class TestZombieInfo {
        public float X;
        public float Y;
        public long event;
        public long inst;

        public TestZombieInfo(long j, float f, float f2) {
            createZombieInstance(j, f, f2);
        }

        public long createZombieInstance(long j, float f, float f2) {
            long FMOD_Studio_System_CreateEventInstance = javafmod.FMOD_Studio_System_CreateEventInstance(j);
            javafmod.FMOD_Studio_EventInstance3D(FMOD_Studio_System_CreateEventInstance, f, f2, 0.0f);
            javafmod.FMOD_Studio_StartEvent(FMOD_Studio_System_CreateEventInstance);
            this.X = f;
            this.Y = f2;
            this.event = j;
            this.inst = FMOD_Studio_System_CreateEventInstance;
            return FMOD_Studio_System_CreateEventInstance;
        }
    }

    private void loadZombieTest() {
        long FMOD_Studio_System_LoadBankFile = javafmod.FMOD_Studio_System_LoadBankFile("media/sound/banks/chopper.bank");
        javafmod.FMOD_Studio_System_LoadBankFile("media/sound/banks/chopper.strings.bank");
        javafmod.FMOD_Studio_LoadSampleData(FMOD_Studio_System_LoadBankFile);
        long FMOD_Studio_System_GetEvent = javafmod.FMOD_Studio_System_GetEvent("{5deff1b6-984c-42e0-98ec-c133a83d0513}");
        long FMOD_Studio_System_GetEvent2 = javafmod.FMOD_Studio_System_GetEvent("{c00fed39-230a-4c6a-b9c0-b0924876f53a}");
        javafmod.FMOD_Studio_LoadEventSampleData(FMOD_Studio_System_GetEvent);
        javafmod.FMOD_Studio_LoadEventSampleData(FMOD_Studio_System_GetEvent2);
        SoundListener soundListener = new SoundListener(0);
        soundListener.x = 2000;
        soundListener.y = 2000;
        soundListener.tick();
        ArrayList arrayList = new ArrayList();
        ArrayList arrayList2 = new ArrayList();
        TestZombieInfo testZombieInfo = new TestZombieInfo(FMOD_Studio_System_GetEvent, 2000 - 5, 2000 - 5);
        javafmod.FMOD_Studio_EventInstance_SetParameterByName(testZombieInfo.inst, "Pitch", (Rand.Next(200) / 100.0f) - 1.0f);
        javafmod.FMOD_Studio_EventInstance_SetParameterByName(testZombieInfo.inst, "Aggitation", 0.0f);
        arrayList.add(testZombieInfo);
        this.c++;
        while (0 == 0) {
            int i = 0;
            while (i < arrayList.size()) {
                TestZombieInfo testZombieInfo2 = (TestZombieInfo) arrayList.get(i);
                if (Rand.Next(1000) == 0) {
                    this.c--;
                    arrayList2.add(testZombieInfo2);
                    arrayList.remove(testZombieInfo2);
                    javafmod.FMOD_Studio_EventInstance_SetParameterByName(testZombieInfo2.inst, "Aggitation", (Rand.Next(40) + 60) / 100.0f);
                    i--;
                }
                i++;
            }
            for (int i2 = 0; i2 < arrayList2.size(); i2++) {
                TestZombieInfo testZombieInfo3 = (TestZombieInfo) arrayList2.get(i2);
                Vector2 vector2 = new Vector2(2000 - testZombieInfo3.X, 2000 - testZombieInfo3.Y);
                if (vector2.getLength() < 2.0f) {
                    arrayList2.remove(testZombieInfo3);
                    javafmod.FMOD_Studio_EventInstance_Stop(testZombieInfo3.inst, false);
                }
                vector2.setLength(0.01f);
                testZombieInfo3.X += vector2.x;
                testZombieInfo3.Y += vector2.y;
                javafmod.FMOD_Studio_EventInstance3D(testZombieInfo3.inst, testZombieInfo3.X, testZombieInfo3.Y, 0.0f);
            }
            javafmod.FMOD_System_Update();
            try {
                Thread.sleep(10L);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }
    }

    private void loadTestEvent() {
        javafmod.FMOD_Studio_LoadSampleData(javafmod.FMOD_Studio_System_LoadBankFile("media/sound/banks/chopper.bank"));
        long FMOD_Studio_System_GetEvent = javafmod.FMOD_Studio_System_GetEvent("{47d0c496-7d0a-48e9-9bad-1c8fcf292986}");
        javafmod.FMOD_Studio_LoadEventSampleData(FMOD_Studio_System_GetEvent);
        long FMOD_Studio_System_CreateEventInstance = javafmod.FMOD_Studio_System_CreateEventInstance(FMOD_Studio_System_GetEvent);
        javafmod.FMOD_Studio_EventInstance3D(FMOD_Studio_System_CreateEventInstance, this.pos.x, this.pos.y, 100.0f);
        javafmod.FMOD_Studio_Listener3D(0, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f);
        javafmod.FMOD_Studio_StartEvent(FMOD_Studio_System_CreateEventInstance);
        int i = 0;
        while (0 == 0) {
            if (i > 200) {
                this.pos.x = Rand.Next(400) - 200;
                this.pos.y = Rand.Next(400) - 200;
                if (Rand.Next(3) == 0) {
                    this.pos.x /= 4.0f;
                    this.pos.y /= 4.0f;
                }
                javafmod.FMOD_Studio_StartEvent(FMOD_Studio_System_CreateEventInstance);
                javafmod.FMOD_Studio_EventInstance3D(FMOD_Studio_System_CreateEventInstance, this.pos.x, this.pos.y, 0.0f);
                i = 0;
            }
            i++;
            javafmod.FMOD_System_Update();
            try {
                Thread.sleep(10L);
            } catch (InterruptedException e) {
                e.printStackTrace();
            }
        }
    }

    public void loadTest() {
        long FMOD_System_CreateSound = javafmod.FMOD_System_CreateSound("media/sound/PZ_FemaleBeingEaten_Death.wav", FMOD_3D);
        javafmod.FMOD_Sound_Set3DMinMaxDistance(FMOD_System_CreateSound, 0.005f, 100.0f);
        this.Sounds.add(Long.valueOf(FMOD_System_CreateSound));
        playTest();
    }

    public void playTest() {
        long FMOD_System_PlaySound = javafmod.FMOD_System_PlaySound(this.Sounds.get(0).longValue(), true);
        javafmod.FMOD_Channel_Set3DAttributes(FMOD_System_PlaySound, 10.0f, 10.0f, 0.0f, 0.0f, 0.0f, 0.0f);
        javafmod.FMOD_Channel_SetPaused(FMOD_System_PlaySound, false);
        this.Instances.add(Long.valueOf(FMOD_System_PlaySound));
    }

    public void applyDSP() {
        javafmod.FMOD_System_PlayDSP();
    }

    public void tick() {
        if (Rand.Next(100) == 0) {
            this.vx = -this.vx;
        }
        if (Rand.Next(100) == 0) {
            this.vy = -this.vy;
        }
        float f = this.x;
        float f2 = this.y;
        float f3 = this.z;
        this.x += this.vx;
        this.y += this.vy;
        this.z += this.vz;
        for (int i = 0; i < this.Instances.size(); i++) {
            long longValue = this.Instances.get(i).longValue();
            javafmod.FMOD_Channel_Set3DAttributes(longValue, this.x, this.y, this.z, this.x - f, this.y - f2, this.z - f3);
            float abs = (Math.abs(this.x) + Math.abs(this.y)) / 40.0f;
            if (abs < 0.1f) {
                abs = 0.1f;
            }
            if (abs > 1.0f) {
                abs = 1.0f;
            }
            javafmod.FMOD_Channel_SetReverbProperties(longValue, 0, abs * abs * 40.0f);
        }
        int i2 = 0;
        for (int i3 = 0; i3 < IsoPlayer.numPlayers; i3++) {
            if (IsoPlayer.players[i3] != null) {
                i2++;
            }
        }
        if (i2 > 0) {
            if (i2 != this.numListeners) {
                javafmod.FMOD_Studio_SetNumListeners(i2);
            }
        } else if (this.numListeners != 1) {
            javafmod.FMOD_Studio_SetNumListeners(1);
        }
        this.numListeners = i2;
        updateReverbPreset();
        javafmod.FMOD_System_Update();
    }

    public int getNumListeners() {
        return this.numListeners;
    }

    public long loadSound(String str) {
        String absolutePath = ZomboidFileSystem.instance.getAbsolutePath(str);
        if (absolutePath == null) {
            return 0L;
        }
        Long l = this.fileToSoundMap.get(absolutePath);
        if (l != null) {
            return l.longValue();
        }
        Long valueOf = Long.valueOf(javafmod.FMOD_System_CreateSound(absolutePath, FMOD_3D));
        if (Core.bDebug && valueOf.longValue() == 0) {
            DebugLog.log("ERROR: failed to load sound " + absolutePath);
        }
        this.fileToSoundMap.put(absolutePath, valueOf);
        return valueOf.longValue();
    }

    public void stopSound(long j) {
        if (j == 0) {
            return;
        }
        javafmod.FMOD_Channel_Stop(j);
    }

    public boolean isPlaying(long j) {
        return javafmod.FMOD_Channel_IsPlaying(j);
    }

    public long loadSound(String str, boolean z) {
        Long valueOf;
        String absolutePath = ZomboidFileSystem.instance.getAbsolutePath(str);
        if (absolutePath == null) {
            return 0L;
        }
        Long l = this.fileToSoundMap.get(absolutePath);
        if (l != null) {
            return l.longValue();
        }
        if (!z) {
            valueOf = Long.valueOf(javafmod.FMOD_System_CreateSound(absolutePath, FMOD_3D));
        } else {
            valueOf = Long.valueOf(javafmod.FMOD_System_CreateSound(absolutePath, FMOD_3D | FMOD_LOOP_NORMAL));
        }
        this.fileToSoundMap.put(absolutePath, valueOf);
        return valueOf.longValue();
    }

    public void updateReverbPreset() {
        int i = FMOD_PRESET_FOREST;
        int i2 = FMOD_PRESET_CITY;
        int i3 = FMOD_PRESET_OFF;
        int i4 = FMOD_PRESET_OFF;
        int i5 = FMOD_PRESET_OFF;
        if (this.reverbPreset[0] != i3) {
            javafmod.FMOD_System_SetReverbDefault(0, i3);
            this.reverbPreset[0] = i3;
        }
        if (this.reverbPreset[1] != i4) {
            javafmod.FMOD_System_SetReverbDefault(1, i4);
            this.reverbPreset[1] = i4;
        }
        if (this.reverbPreset[2] != i5) {
            javafmod.FMOD_System_SetReverbDefault(2, i5);
            this.reverbPreset[2] = i5;
        }
    }

    private void initGlobalParameters() {
        int FMOD_Studio_System_GetParameterDescriptionCount = javafmodJNI.FMOD_Studio_System_GetParameterDescriptionCount();
        if (FMOD_Studio_System_GetParameterDescriptionCount <= 0) {
            return;
        }
        long[] jArr = new long[FMOD_Studio_System_GetParameterDescriptionCount];
        int FMOD_Studio_System_GetParameterDescriptionList = javafmodJNI.FMOD_Studio_System_GetParameterDescriptionList(jArr);
        for (int i = 0; i < FMOD_Studio_System_GetParameterDescriptionList; i++) {
            long j = jArr[i];
            initParameterDescription(j);
            javafmodJNI.FMOD_Studio_ParameterDescription_Free(j);
        }
    }

    private FMOD_STUDIO_PARAMETER_DESCRIPTION initParameterDescription(long j) {
        String FMOD_Studio_ParameterDescription_GetName = javafmodJNI.FMOD_Studio_ParameterDescription_GetName(j);
        FMOD_STUDIO_PARAMETER_DESCRIPTION fmod_studio_parameter_description = this.parameterDescriptionMap.get(FMOD_Studio_ParameterDescription_GetName);
        if (fmod_studio_parameter_description == null) {
            fmod_studio_parameter_description = new FMOD_STUDIO_PARAMETER_DESCRIPTION(FMOD_Studio_ParameterDescription_GetName, new FMOD_STUDIO_PARAMETER_ID(javafmodJNI.FMOD_Studio_ParameterDescription_GetID(j)), javafmodJNI.FMOD_Studio_ParameterDescription_GetFlags(j), this.parameterDescriptionMap.size());
            this.parameterDescriptionMap.put(fmod_studio_parameter_description.name, fmod_studio_parameter_description);
            if ((fmod_studio_parameter_description.flags & FMOD_STUDIO_PARAMETER_FLAGS.FMOD_STUDIO_PARAMETER_GLOBAL.bit) != 0) {
            }
        }
        return fmod_studio_parameter_description;
    }

    private void initEvents() {
        int FMOD_Studio_System_GetBankCount = javafmodJNI.FMOD_Studio_System_GetBankCount();
        if (FMOD_Studio_System_GetBankCount <= 0) {
            return;
        }
        long[] jArr = new long[FMOD_Studio_System_GetBankCount];
        int FMOD_Studio_System_GetBankList = javafmodJNI.FMOD_Studio_System_GetBankList(jArr);
        for (int i = 0; i < FMOD_Studio_System_GetBankList; i++) {
            int FMOD_Studio_Bank_GetEventCount = javafmodJNI.FMOD_Studio_Bank_GetEventCount(jArr[i]);
            if (FMOD_Studio_Bank_GetEventCount > 0) {
                long[] jArr2 = new long[FMOD_Studio_Bank_GetEventCount];
                int FMOD_Studio_Bank_GetEventList = javafmodJNI.FMOD_Studio_Bank_GetEventList(jArr[i], jArr2);
                for (int i2 = 0; i2 < FMOD_Studio_Bank_GetEventList; i2++) {
                    initEvent(jArr2[i2]);
                }
            }
        }
    }

    private void initEvent(long j) {
        FMOD_STUDIO_EVENT_DESCRIPTION fmod_studio_event_description = new FMOD_STUDIO_EVENT_DESCRIPTION(j, javafmodJNI.FMOD_Studio_EventDescription_GetPath(j), new FMOD_GUID(javafmodJNI.FMOD_Studio_EventDescription_GetID(j)), javafmodJNI.FMOD_Studio_EventDescription_HasSustainPoint(j), javafmodJNI.FMOD_Studio_EventDescription_GetLength(j));
        this.eventDescriptionMap.put(fmod_studio_event_description.path.toLowerCase(Locale.ENGLISH), fmod_studio_event_description);
        int FMOD_Studio_EventDescription_GetParameterDescriptionCount = javafmodJNI.FMOD_Studio_EventDescription_GetParameterDescriptionCount(j);
        for (int i = 0; i < FMOD_Studio_EventDescription_GetParameterDescriptionCount; i++) {
            long FMOD_Studio_EventDescription_GetParameterDescriptionByIndex = javafmodJNI.FMOD_Studio_EventDescription_GetParameterDescriptionByIndex(j, i);
            fmod_studio_event_description.parameters.add(initParameterDescription(FMOD_Studio_EventDescription_GetParameterDescriptionByIndex));
            javafmodJNI.FMOD_Studio_ParameterDescription_Free(FMOD_Studio_EventDescription_GetParameterDescriptionByIndex);
        }
    }

    public FMOD_STUDIO_EVENT_DESCRIPTION getEventDescription(String str) {
        return this.eventDescriptionMap.get(str.toLowerCase(Locale.ENGLISH));
    }

    public FMOD_STUDIO_PARAMETER_DESCRIPTION getParameterDescription(String str) {
        return this.parameterDescriptionMap.get(str);
    }

    public FMOD_STUDIO_PARAMETER_ID getParameterID(String str) {
        FMOD_STUDIO_PARAMETER_DESCRIPTION parameterDescription = getParameterDescription(str);
        if (parameterDescription == null) {
            return null;
        }
        return parameterDescription.id;
    }

    public int getParameterCount() {
        return this.parameterDescriptionMap.size();
    }
}